#include "parameters.h"
#include "ljforce.h"
#include "md.h"
#include <fstream>

void RunDynamics()
{
// set parameters for simulation, molecular system, force fields
std::string parameter_file = "parameters.txt";
std::ifstream ifs(parameter_file);
if (ifs.good())
{
    ReadParameters(parameter_file);
}
// construct object of molecular system
MolSys mol;

// set force field
Force *pForce = nullptr;
if (gForceType == ForceTypes::kLennardJones)
{
    LjForce lj(gLjSigma, gLjEpsilon);
    pForce = &lj;
}
// start simulation: do job according to job_type
// std::cout << "Job starts" << std::endl;

if (gDynamicsType == DynamicsTypes::kMd)
{
    Md md;
    // initialize and evolve
    md.Initialize(mol, *pForce);

    md.Evolve(mol, *pForce);

}
}

// end simulation
